package com.itheima.demo;


import java.io.FileReader;
import java.io.IOException;
import java.util.Properties;
import java.util.Set;

/**
 * @author Zhang_Han
 * @version 1.0
 * @date 2020/7/11 19:08
 */
public class Demo_Load002 {
    public static void main(String[] args) throws IOException {
        Properties prop = new Properties();
        FileReader fr = new FileReader("demo_properties\\pop1.properties");
        prop.load(fr);
        fr.close();
        Set<String> keys = prop.stringPropertyNames();
        for (String key : keys) {
            String value = prop.getProperty(key);
            System.out.println(key + "..." + value);
        }
    }
}
